/*
 * Copyright (C) 2014 Francisco José Morero Peyrona. All Rights Reserved.
 *
 * This file is part of JStatViewer project: https://code.google.com/p/jstat-viewer/
 *
 * GNU Classpath is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License as published by the free
 * Software Foundation; either version 3, or (at your option) any later version.
 *
 * Tapas is distributed in the hope that it will be useful, but WITHOUT ANY
 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
 * A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License along with
 * Tapas; see the file COPYING.  If not, write to the Free Software Foundation,
 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
 */

package jstatviewer;

import java.awt.EventQueue;
import javax.swing.JFrame;
import jstatviewer.ui.MainPanel;

/**
 * Application entry point.
 *
 * @author peyrona
 */
public class Main
{
    private static JFrame frame;

    //----------------------------------------------------------------------------//

    private Main()
    {
        frame = new JFrame( "JStat Viewer  :::  Ver. 1.1" );
        frame.setDefaultCloseOperation( JFrame.EXIT_ON_CLOSE );

        EventQueue.invokeLater( new Runnable()
        {
            @Override
            public void run()
            {
                frame.setContentPane( new MainPanel() );
                frame.pack();
                frame.setSize( 1024, 650 );
                frame.setVisible( true );
            }
        } );
    }

    //----------------------------------------------------------------------------//

    public static JFrame getFrame()
    {
        return frame;
    }

    //----------------------------------------------------------------------------//

    /**
     * @param args the command line arguments
     */
    public static void main( String[] args )
    {
        Util.setLookAndFeel();
        new Main();
    }
}